package br.com.flexdev.business.factory;

import java.util.Collection;

import br.com.flexdev.business.vo.NivelAcessoVO;
import br.com.flexdev.persistence.dao.DaoNivelAcesso;

public class FactoryNivelAcesso implements IFactory {

	private DaoNivelAcesso daoNivelAcesso;

	public FactoryNivelAcesso() throws Exception {
		super();
		this.init();
	}

	public void init() throws Exception {
		this.daoNivelAcesso = new DaoNivelAcesso();
		this.setNivelAcessoVO(new NivelAcessoVO());
	}

	public Object salvar() throws Exception {
		try {
			return this.daoNivelAcesso.salvar();
		} catch (Exception e) {
			throw e;
		}
	}

	public void excluir() throws Exception {
		try {
			this.daoNivelAcesso.excluir();
		} catch (Exception e) {
			throw e;
		}
	}

	public NivelAcessoVO obter() throws Exception {
		try {
			return this.daoNivelAcesso.obter();
		} catch (Exception e) {
			throw e;
		}
	}

	public Collection<?> obterLista() throws Exception {
		try {
			return this.daoNivelAcesso.obterLista();
		} catch (Exception e) {
			throw e;
		}
	}

	public void setNivelAcessoVO(NivelAcessoVO param) {
		this.daoNivelAcesso.setNivelAcessoVO(param);
	}

	public NivelAcessoVO getNivelAcessoVO() {
		return this.daoNivelAcesso.getNivelAcessoVO();
	}

}
